import Vue from 'vue'
import Router from 'vue-router'
import login from '../background/login/login.vue'
import backhome from '../background/home.vue'
import emlserver from '../background/emlserver.vue'
import emljavax from '../background/emljavax.vue'
import emlindex from '../background/emlindex.vue'
import statisticfrom from '../background/statisticfrom.vue'
import statisticdate from '../background/statisticdate.vue'
import line from '../background/line.vue'
import infomodify from '../background/infomodify.vue'
import usermanager from '../background/usermanager.vue'
import searcheml from '../background/searcheml.vue'
import searchpage from '../background/searchpage.vue'
import detail_eml from '../background/detail_eml.vue'
import scrollpicture from '../background/scrollpicture.vue'
import uploadfile from '../background/uploadfile.vue'
import imappop3 from '../background/imappop3.vue'
import detail_imap from '../background/detail_imap.vue'
import register from '../background/register/register.vue'
Vue.use(Router)
export default new Router({
  routes: [

    //后台路由
    {
      path: '/',
      name: 'login',
      component: login,
    },
    {
      path: '/backhome',
      name: 'backhome',
      component: backhome,
      children: [

        {
          path: '/backhome/emlserver',
          name: 'emlserver',
          component: emlserver,
        },
        {
          path: '/backhome/emljavax',
          name: 'emljavax',
          component: emljavax,
        },
        {
          path: '/backhome/emlindex',
          name: 'emlindex',
          component: emlindex,
        },
        {
          path: '/backhome/statisticfrom',
          name: 'statisticfrom',
          component: statisticfrom,
        },
        {
          path: '/backhome/statisticdate',
          name: 'statisticdate',
          component: statisticdate,
        },
        {
          path: '/backhome/line',
          name: 'line',
          component: line,
        },
        {
          path: '/backhome/infomodify',
          name: 'infomodify',
          component: infomodify,
        },
        {
          path: '/backhome/usermanager',
          name: 'usermanager',
          component: usermanager,
        },
        {
          path: '/backhome/searcheml',
          name: 'searcheml',
          component: searcheml,
        },
        {
          path: '/backhome/scrollpicture',
          name: 'scrollpicture',
          component: scrollpicture,
        },
        {
          path: '/backhome/uploadfile',
          name: 'uploadfile',
          component: uploadfile,
        },
        {
          path: '/backhome/imappop3',
          name: 'imappop3',
          component: imappop3,
        },
      ]
    },
    {
      path: '/backhome/searcheml/searchpage',
      name: 'searchpage',
      component: searchpage,
    },
    {

      path: '/backhome/searcheml/searchpage/detail_eml',
      name: 'detail_eml',
      component: detail_eml,
    },
    {

      path: '/backhome/scrollpicture/detail_eml',
      name: 'detail_eml',
      component: detail_eml,
    },
    {

      path: '/backhome/imappop3/detail_imap',
      name: 'detail_imap',
      component: detail_imap,
    },
    {

      path: '/register',
      name: 'register',
      component: register,
    },


//前台路由
/*     {
      path: '/fronthome',
      name: 'fronthome',
      component: fronthome,
      //子页面--子路由
      children: [
        {
          path: '/fronthome/searcheml',
          name: 'searcheml',
          component: searcheml,
        },
        {
          path: '/fronthome/imap',
          name: 'imap',
          component: imap,
        },
        {
          path: '/fronthome/upload',
          name: 'upload',
          component: upload,
        },
        {
          path: '/fronthome/scrollpicture',
          name: 'scrollpicture',
          component: scrollpicture,
        },
      ]
    },
    //新页面--缀加路由
    {
      path: '/fronthome/searcheml/searchpage',
      name: 'searchpage',
      component: searchpage,
    },
    //新页面--缀加路由
    {
      path: '/fronthome/imap/imapdetail',
      name: 'imapdetail',
      component: imapdetail,
    },
    {

      path: '/fronthome/searcheml/searchdetail',
      name: 'searchdetail',
      component: searchdetail,
    }, */


  ]


})
